<template>
  <div :class="$style.page" :style="bg">
    <div :class="$style.buttonWrap" @click="goLink">
      <span :class="$style.text">查看全景图</span>
      <span :class="$style.arrow">
        <img src="~/static/images/Rectangle2.png" alt>
      </span>
    </div>
  </div>
</template>
<script>
export default {
  props: ["data"],
  methods: {
    goLink() {
      window.open(this.data.pano.url);
    }
  },
  computed: {
    bg() {
      let url = this.data.mlogo;
      return {
        background: `url(${url}) 0 0 no-repeat /cover`
      };
    }
  }
};
</script>
<style lang="less" module>
.page {
  .buttonWrap {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate3d(-50%, 0, 0);
    width: 222px;
    height: 62px;
    background: rgba(51, 51, 51, 0.6);
    border-radius: 28px;
    border: 1px solid #fdc15f;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    .text {
      font-size: 24px;
      color: #fff;
      padding-right: 12px;
    }
    .arrow {
      > img {
        width: 14px;
        height: 23px;
        vertical-align: middle;
        margin-top: -10px;
      }
    }
  }
}
</style>
